<template>
	<view>
		<web-view :webview-styles="webviewStyles" src="https://fileweb.xiaohong.work/"></web-view>
		<!-- <web-view :webview-styles="webviewStyles" src="/hybrid/html/upload.html"></web-view> -->
		<!-- <uni-group title="上传说明">
			<textarea
			focus
			auto-height
			v-model="fileDescription"
			style="width: 100%;min-height: 100rpx;"
			:maxlength="-1"
			placeholder="请先填写后再上传哦(͏ ˉ ꈊ ˉ)✧˖°" />
		</uni-group> -->
		<!-- #ifndef APP-PLUS -->
		<!-- <upload-file-web
		:fileDescription = "fileDescription"
		:url="uploadUrl"
		:limit = "100"
		></upload-file-web> -->
		<!-- <uni-group title="只选择图片">
			<upload-image
			:fileDescription = "fileDescription"
			:url="uploadUrl"
			:limit = "100"
			></upload-image>
		</uni-group>
		<uni-group title="只选择视频">
			<upload-video
			:fileDescription = "fileDescription"
			:url="uploadUrl"
			:limit = "100"
			></upload-video>
		</uni-group>
		<uni-group title="选择任意文件">
			<upload-file
			:fileDescription = "fileDescription"
			:url="uploadUrl"
			></upload-file>
		</uni-group> -->
		
		<!-- <upload-file-web
		:fileDescription = "fileDescription"
		:url="uploadUrl"
		>
		</upload-file-web> -->
		
		<!-- <web-view src="/static/upload.html" style="height: 100%;"></web-view> -->
		
		<!-- <status-bar :uppy="uppy" ></status-bar> -->
		<!-- <dashboard-modal :uppy="uppy" open="tes" ></dashboard-modal> -->
		<!-- <status-bar></status-bar> -->
		
		
		<!-- #endif -->
		<!-- #ifdef APP-PLUS -->
		<!-- <uni-group title="选择文件">
			<upload-file-android
			:fileDescription = "fileDescription"
			:url="uploadUrl"
			></upload-file-android>
		</uni-group> -->
		<!-- #endif -->
		
	</view>
</template>

<script>
	//引入js文件
	import browser from '../../js_sdk/ww-browser/libs/browser.js'
	
	var wv; //计划创建的webview
	export default {
		data() {
			return {
				webviewStyles: {
					progress: {
						color: '#ffaa00'
					}
				},
				uploadUrl: this.utils.basicUrl+"/file/upload",
				fileDescription: "",
			}
		},
		onReady() {
			
			//使用
			// var options = {
			//     'data': '' // 自定义参数
			// }
			// browser.init(options)
			// browser.show("https://www.baidu.com")
			
			// #ifdef APP-PLUS
			var currentWebview = this.$mp.page.$getAppWebview() //获取当前页面的webview对象
			setTimeout(function() {
				wv = currentWebview.children()[0]
				wv.setStyle({
					scalable: true
				})
			}, 1000); //如果是页面初始化调用时，需要延时一下
			// #endif
		},
		// onBackPress() {
		// 	uni.reLaunch({
		// 		url:"../index/index"
		// 	})
		// },
		methods: {
			
		}
	}
</script>

<style>
	@import url("upload.css");
</style>